<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<meta name="viewport" content="width=1000, initial-scale=1.0, maximum-scale=1.0">
	    <include file='__VIEW__/Common/header' />
	</head>
	<body>
		<table class="table table-hover">
			<tr class="active">
			  <th width="30">ID</th>
			  <th>商品名称</th>
			  <th>价格</th>
			  <th>库存</th>
			  <th>点击数</th>
			  <th>添加时间</th>
			  <th width="260">操作</th>
			</tr>
			<if value="empty($goodsData)">
				<tr><td colspan="3">还没有商品</td></tr>
			<else />
				<foreach from="$goodsData" key="$k" value="$v">
					<tr>
						<td>{$v.gid}</td>
						<td>{$v.gname}</td>
						<td>市场价：{$v.gmarketprice}<br />商城价：{$v.gshopprice}</td>
						<td>{$v.gallinventory}</td>
						<td>{$v.gclick}</td>
						<td>{$v.guptime|date:"Y-m-d",@@}</td>
						<td>
							<a href="{|U:'GoodsList/index',array('gid'=>$v['gid'])}" class="btn btn-sm btn-success">货品列表</a>
							<a href="{|U:'edit',array('gid'=>$v['gid'])}" class="btn btn-sm btn-warning">编辑</a>
							<a href="javascript:;" class="btn btn-sm btn-danger" onclick="del('{|U:'del',array('gid'=>$v['gid'])}')">删除</a>
						</td>
					</tr>
				</foreach>
			</if>
		</table>
		<div id="page">{$pageData}</div>
	</body>
</html>
